package coco.wx.com.module.question.controller;

import coco.wx.com.common.dto.TempMap;
import coco.wx.com.module.question.service.QuestionService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.*;

/**
 *  题目前端控制器
 *
 * @author srx
 * @since 2020-10-23
 */
@RestController
@RequestMapping("/question")
public class QuestionController {

    @Autowired
    private QuestionService questionService;

    @PostMapping("/getQuestionsSort")
    public ResponseEntity<Object> getQuestionsSort(@RequestBody TempMap dto) {

        return questionService.getQuestionsSort(dto);
    }

    @PostMapping("/getQuestionsNoSort")
    public ResponseEntity<Object> getQuestionsNoSort(@RequestBody TempMap dto) {

        return questionService.getQuestionsNoSort(dto);
    }

}
